Skip to content

Fix: resolve zizmor auditor persona findings - #120

Merged
tykeal merged 1 commit into
lfreleng-actions:mainfrom
modeseven-lfreleng-actions:fix/zizmor-auditor-findings
Jul 8, 2026
Merged

Fix: resolve zizmor auditor persona findings#120
tykeal merged 1 commit into
lfreleng-actions:mainfrom
modeseven-lfreleng-actions:fix/zizmor-auditor-findings

Conversation

@ModeSevenIndustrialSolutions

Copy link
Copy Markdown
Contributor

Summary

Resolves the zizmor auditor persona findings (min-severity: low)
that fail the organisation's required "Audit Workflows" gate and block
Dependabot pull requests from merging.

Method

  • Boilerplate workflows (tag-push, release-drafter) that
    carried findings were replaced byte-for-byte with the canonical
    versions from actions-template. This adds the workflow-level
    concurrency group (concurrency-limits), harden-runner block-mode
    egress via harden-runner-block-action, and documented permission
    scopes (undocumented-permissions).
  • testing.yaml: added a workflow-level concurrency group
    (concurrency-limits) and persist-credentials: false on both
    checkout steps (artipacked).
  • action.yaml: all ${{ inputs.* }} expressions were hoisted out
    of run: blocks into step-level environment variables and are now
    referenced as quoted shell variables (template-injection). The
    dangerous $GITHUB_ENV writes were replaced with $GITHUB_OUTPUT
    step outputs (github-env): the setup step publishes path_prefix,
    the dependency-install step publishes kernel_flags / flags, and
    downstream steps consume them via steps.<id>.outputs.* hoisted into
    their own step environments. Shell behaviour (word splitting of flag
    variables, glob expansion of the notebook path) is preserved.

Verified with zizmor --persona auditor --min-severity low (clean),
with no action pin downgrades.

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR aims to clear zizmor “auditor” persona findings that block Dependabot merges by hardening workflows and reducing template-injection risk in the composite action.

Changes:

  • Updated composite action.yaml to hoist ${{ inputs.* }} out of run: blocks and replace $GITHUB_ENV writes with step outputs via $GITHUB_OUTPUT.
  • Added workflow-level concurrency controls and persist-credentials: false to reduce credential persistence and improve workflow safety.
  • Replaced/tag-aligned release workflows with hardened-runner “block” mode and documented permission scopes.

Reviewed changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated 4 comments.

File Description
action.yaml Reworks composite-action input handling and output propagation to address template-injection and $GITHUB_ENV findings.
.github/workflows/testing.yaml Adds workflow concurrency and disables credential persistence on checkout steps.
.github/workflows/tag-push.yaml Adds workflow concurrency and hardens runner egress policy using an allow-list + block mode.
.github/workflows/release-drafter.yaml Adds workflow concurrency, hardens runner egress policy, and updates the release-drafter pin.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread action.yaml
Comment thread action.yaml Outdated
Comment thread action.yaml Outdated
Comment thread action.yaml Outdated
Copilot AI review requested due to automatic review settings July 8, 2026 13:41

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 4 out of 4 changed files in this pull request and generated 4 comments.

Comment thread action.yaml Outdated
Comment thread action.yaml Outdated
Comment thread action.yaml
Comment thread action.yaml Outdated
Resolve the zizmor auditor-persona findings (min-severity low) that
fail the organisation's required "Audit Workflows" gate and block
Dependabot pull requests from merging.

- Replace the boilerplate `tag-push` and `release-drafter` workflows
  with the canonical `actions-template` versions. This adds the
  workflow-level `concurrency` group (`concurrency-limits`),
  harden-runner block-mode egress via `harden-runner-block-action`,
  and documented permission scopes (`undocumented-permissions`).
- testing.yaml: add a workflow-level `concurrency` group
  (`concurrency-limits`) and set `persist-credentials: false` on both
  checkout steps (`artipacked`).
- action.yaml: hoist all `${{ inputs.* }}` expressions out of `run:`
  blocks into step-level environment variables and reference them as
  quoted shell variables (`template-injection`). Replace the dangerous
  `$GITHUB_ENV` writes with `$GITHUB_OUTPUT` step outputs
  (`github-env`): the setup step now publishes `path_prefix` and the
  dependency-install step publishes `kernel_flags` and `flags`;
  downstream steps consume these via `steps.<id>.outputs.*` hoisted
  into their own step environments. Shell behaviour (word splitting
  of flags, glob expansion of the notebook path) is preserved.

Verified clean with:
zizmor --persona auditor --min-severity low

Co-Authored-By: Claude <noreply@anthropic.com>
Signed-off-by: Matthew Watkins <mwatkins@linuxfoundation.org>
Copilot AI review requested due to automatic review settings July 8, 2026 14:06

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 4 out of 4 changed files in this pull request and generated no new comments.

@tykeal tykeal left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🤖 Dependamerge
Approved this pull request ✅

@tykeal
tykeal merged commit 04e7504 into lfreleng-actions:main Jul 8, 2026
9 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants